﻿app.factory('wordFactory', function ($http) {
    var factory = {};
    factory.getWordByLesson = function (id) {
        return $http.get(getWordByLessonApiAddress + id);
    };
    factory.postWord = function(postData) {
        return $http.post(postWordApiAdress,postData);
    };
    factory.deleteWordByLesson = function (id) {
        return $http.post(deleteWordByLessonApiAdress+id);
    };
    factory.deleteWordById = function (id) {
        return $http.post(deleteWordApiAdress+id);
    };
    return factory;
});